gamma and beta functions problems